import { IsNotEmpty } from "class-validator";
import { Transform } from "class-transformer";
export class PostDto {
  @IsNotEmpty({ message: "标题是必填的" })
  @Transform((title) => title.value.trim())
  title: string;

  @IsNotEmpty({ message: "内容是必填的" })
  @Transform((content) => content.value.trim())
  content: string;
}
